   

#ifndef DISPLAY_MENUE_H_
#define DISPLAY_MENUE_H_
   
    /* includes:   */
    #include "SDL/SDL.h"
    #include "SDL/SDL_image.h"
    #include "SDL/SDL_ttf.h"
    #include <stdint.h>
    #include <stdio.h>
    #include <time.h>
    #include <stdlib.h>
    #include "libgeisyr.h"

   /* defines:   */
   //home
   #define MAINWINDOW           0b00000001
   #define CHOOSEWINDOW         0b00000010
   #define SHOWWINDOWWORK       0b00000100
   #define SHOWWINDOWBATH       0b00000101
   #define SHOWWINDOWLIVING     0b00000110
   #define SHOWWINDOWKITCHEN    0b00000111 
   #define SHOWWINDOWSLEEP      0b00001000
   
   //work
   #define MAINWINDOW_WORK      0b00001001
   #define ROOMLIST             0b00001010
   #define FIRST_BUREAU         0b00001011
   #define SECOND_BUREAU        0b00001100
   #define FIRST_SEMINAR_ROOM   0b00001101
   #define SECOND_SEMINAR_ROOM  0b00001110
   #define THIRD_SEMINAR_ROOM   0b00001111
   #define FOURT_SEMINAR_ROOM   0b00010000

   #define PROGRAM_EXIT         0b00011111

   //home button pressed
   #define NEXT_BUTTON    0x01
   #define WORK_BUTTON    0x02
   #define BATH_BUTTON    0x03
   #define LIVING_BUTTON  0x04
   #define KITCHEN_BUTTON 0x05
   #define SLEEP_BUTTON   0x06
   #define HOME_BUTTON    0x07
   #define BACK_BUTTON    0x08
   #define ROOM_BUTTON    0x09

   //work button pressed
   #define SEMI1_BUTTON   0x0A
   #define SEMI2_BUTTON   0x0B
   #define SEMI3_BUTTON   0x0C
   #define SEMI4_BUTTON   0x0D
   #define BUREAU1_BUTTON 0x0E
   #define BUREAU2_BUTTON 0x0F
   #define SEMI_BUTTON    0x1F
   #define HIDDEN_BUTTON  0xFF
               
   typedef struct {

     /* Pictures */
     SDL_Surface *next_button;
     SDL_Surface *home_button;
     SDL_Surface *back_button;
     SDL_Surface *main_frame;
     SDL_Surface *time_frame;

     /* Pictures home */
     SDL_Surface *thermometer_pic;
     SDL_Surface *small_thermometer_pic;
     SDL_Surface *window_pic;
     SDL_Surface *work_frame;
     SDL_Surface *living_frame;
     SDL_Surface *bath_frame;
     SDL_Surface *kitchen_frame;
     SDL_Surface *sleep_frame;
     SDL_Surface *roomtempr_frame;
     SDL_Surface *roomwindow_frame;
     SDL_Surface *roomtitle_frame;

     /* Pictures work */
     SDL_Surface *little_watch_frame;
     SDL_Surface *semi_room_frame;
     SDL_Surface *bureau_frame;
     SDL_Surface *list_title_frame;
     SDL_Surface *timetable_frame;
     SDL_Surface *timetable_info_frame;
     SDL_Surface *semi_room_free_frame;
     SDL_Surface *semi_allocation1_frame;
     SDL_Surface *semi_allocation2_frame;
     SDL_Surface *semi_info_frame;
     SDL_Surface *next_room_info_frame;
     SDL_Surface *red_frame;
     SDL_Surface *green_frame;
     SDL_Surface *red_pic;
     SDL_Surface *green_pic;
     SDL_Surface *red1_pic;
     SDL_Surface *green1_pic;
     SDL_Surface *red2_pic;
     SDL_Surface *green2_pic;
     SDL_Surface *red3_pic;
     SDL_Surface *green3_pic;
     SDL_Surface *info_semi1_button;
     SDL_Surface *info_semi2_button;
     SDL_Surface *info_semi3_button;
     SDL_Surface *info_semi4_button;
     SDL_Surface *info_bureau1_button;
     SDL_Surface *info_bureau2_button;

     /* SDL Variable */
     SDL_Surface *screen;
     SDL_Event   event;

     /* SDL fontcolours */
     SDL_Color white;
     SDL_Color black;
     SDL_Color green;
     SDL_Color red;

     /* SDL text home */
     SDL_Surface *work_text;
     SDL_Surface *living_text;
     SDL_Surface *bath_text;
     SDL_Surface *kitchen_text;
     SDL_Surface *sleep_text;
     SDL_Surface *showwork_text;
     SDL_Surface *showliving_text;
     SDL_Surface *showbath_text;
     SDL_Surface *showkitchen_text;
     SDL_Surface *showsleep_text;
     SDL_Surface *temprin_text;
     SDL_Surface *temprout_text;
     SDL_Surface *windowone_text;
     SDL_Surface *windowtwo_text; 
     SDL_Surface *watch_text; 
     SDL_Surface *roomtempr_text;    

     /* SDL text work */
     SDL_Surface *title_text;
     SDL_Surface *semi1_text;
     SDL_Surface *semi2_text;
     SDL_Surface *semi3_text;
     SDL_Surface *semi4_text; 
     SDL_Surface *roomname_semi1_text; 
     SDL_Surface *roomname_semi2_text; 
     SDL_Surface *roomname_semi3_text; 
     SDL_Surface *roomname_semi4_text; 
     SDL_Surface *roomname_bureau1_text; 
     SDL_Surface *roomname_bureau2_text; 
     SDL_Surface *bureau1_text; 
     SDL_Surface *bureau2_text;   
     SDL_Surface *bureau1_time_text;  
     SDL_Surface *bureau1_time1_text; 
     SDL_Surface *bureau1_time2_text; 
     SDL_Surface *bureau1_time3_text; 
     SDL_Surface *bureau1_time4_text; 
     SDL_Surface *bureau1_time5_text;
     SDL_Surface *bureau1_info1_text; 
     SDL_Surface *bureau1_info2_text;   
     SDL_Surface *bureau2_time_text; 
     SDL_Surface *bureau2_time1_text; 
     SDL_Surface *bureau2_time2_text; 
     SDL_Surface *bureau2_time3_text; 
     SDL_Surface *bureau2_time4_text; 
     SDL_Surface *bureau2_time5_text;
     SDL_Surface *bureau2_info1_text; 
     SDL_Surface *bureau2_info2_text;
     SDL_Surface *semi_text;
     SDL_Surface *semi1_title_text;
     SDL_Surface *semi1_info_text;  
     SDL_Surface *semi2_title_text;
     SDL_Surface *semi2_info_text;
     SDL_Surface *semi3_title_text;
     SDL_Surface *semi3_info_text;
     SDL_Surface *semi4_title_text;
     SDL_Surface *semi4_info_text;
     SDL_Surface *semi_full_text;
     SDL_Surface *semi_free_text;
     SDL_Surface *red_text;
     SDL_Surface *green_text;
     SDL_Surface *roomstat_text;

     /* TTFs */
     TTF_Font *font_liberation_minimal;
     TTF_Font *font_liberation_mini;
     TTF_Font *font_liberation_small;
     TTF_Font *font_liberation_middle;
     TTF_Font *font_liberation_normal;
     TTF_Font *font_liberation_tall;
     TTF_Font *font_liberation_taller;
     TTF_Font *font_liberation_big;

     //timer_event
     SDL_TimerID reflash_timer;
     SDL_TimerID home_timer;

     //libgeisyr:
     double tempr_tmp;


   }display_menue;


 /* funktions */
   
   int  display_init(display_menue *display_tmp ,uint8_t *state);
   void display_clean(display_menue *display_tmp ,uint8_t *state);

 /* funktions home*/
   void display_main_window(display_menue *display_tmp, uint8_t *state);
   void display_choose_window(display_menue *display_tmp, uint8_t *state);
   void display_show_window(display_menue *display_tmp,uint8_t *state);

 /* funktions work*/
   void display_main_window_work(display_menue *display_tmp ,uint8_t *state);
   void display_roomlist_window(display_menue *display_tmp, uint8_t *state);
   void display_bureau_window(display_menue *display_tmp, uint8_t *state);
   void display_seminar_window(display_menue *display_tmp, uint8_t *state);

#endif
